import { createSSRApp } from "vue";
import App from "./App.vue";
import piniaStore from '@/store'
import storage from '@/utils/storage'
import { toPage, goBack } from '@/utils/commonUtils'

// unocss
import 'virtual:uno.css'

export function createApp() {
	const app = createSSRApp(App);
	app.config.globalProperties.$storage = storage
	app.config.globalProperties.$toPage = toPage
	app.config.globalProperties.$goBack = goBack

	app.use(piniaStore)
	return {
		app,
	};
}